﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

using WeChatDemo.Models;
using WeChatDemo.Models.DTO.Photo;

namespace WeChatDemo.DataProvider.Photo
{
    public class DAOPhotoItemDetails: DAOBase
    {
        private static string tableName = "v_Photo_ItemDetails";

        public static IEnumerable<DTOPhotoItem> GetAllList(string orderExpression)
        {
            IEnumerable<DTOPhotoItem> _list = ReaderToList<DTOPhotoItem>(orderExpression, tableName);

            return _list;
        }

        public static IEnumerable<DTOPhotoItem> GetList(string queryExpression)
        {
            IEnumerable<DTOPhotoItem> _list = ReaderToList<DTOPhotoItem>(queryExpression, tableName);

            return _list;
        }

        public static IEnumerable<DTOPhotoItem> GetList(int pageSize, string queryExpression)
        {
            IEnumerable<DTOPhotoItem> _list = ReaderToList<DTOPhotoItem>(pageSize, queryExpression, tableName);

            return _list;
        }
    }
}